home *** CD-ROM | disk | FTP | other *** search
/ The 640 MEG Shareware Studio 2 / The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO / virus / aavirus.zip / AAVIRUS.DOC next >
Text File  |  1992-03-10  |  10KB  |  220 lines

  1. -----------------------------------------------------
  2. AAVIRUS documentation (version of March 10, 1992)
  3.  
  4. by Maarten Meijer, 
  5. Academic Computing Centre University of Utrecht (ACCU),
  6. the Netherlands. 
  7. Email addres: mmeijer@cc.ruu.nl
  8.  
  9.  
  10. -----------------------------------------------------
  11. Contents
  12.  
  13.  
  14. 1. Overview
  15. 2. Usage
  16. 3. Installation
  17. 4. Bootstrap integrity checking
  18. 5. Repair options
  19. 6. Some technical details
  20. 7. Concluding remarks
  21.  
  22.  
  23. -----------------------------------------------------
  24. 1. Overview
  25.  
  26.  
  27. The AAVIRUS ("ACCU Anti Virus") program checks the integrity of the DOS
  28. bootstrap system on a bootable disk against a checksum file created by the
  29. program at installation. 
  30.  
  31. This checksum file also holds a copy of the boot sector of the disk, and 
  32. - if it is a hard disk - a copy of the master boot record, containing the
  33. partition table. 
  34.  
  35. AAVIRUS is able to restore these bootstrap records even if the file is lost
  36. (but not overwritten) or the hard disk has become unaccessible to DOS.
  37.  
  38.  
  39. ------------------------------------------------------
  40. 2. Usage
  41.  
  42.  
  43. Just type "aavirus" to learn about the syntax and the options. The output
  44. looks like this:
  45.  
  46. Usage:    aavirus option [file] [drive]
  47.  
  48. option    -i  installation: creates checksum [file] from [drive]
  49.           -t  test: compares checksum [file] to actual bootstrap on [drive]
  50.           -q  quick test: just compares (master) bootrecord and dir entries
  51.           -r  repair: restores boot record and/or master boot record from
  52.               checksum [file] back to [drive]
  53.           -e  emergency repair: scans hard disk 0 for the most recent
  54.               checksum file data. If file is lost or disk unaccessible.
  55.  
  56. [file]    filename (drive:\path\file) of checksum file. Default is
  57.           "[drive]:\AAVIRUS.DAT".
  58.  
  59. [drive]   drive to protect. Default is current drive (DOS 3.x) or boot
  60.           drive (DOS 4 or higher). If you want to checksum another boot disk
  61.           than the current one, set COMSPEC variable to temporarily point to
  62.           the COMMAND.COM involved.
  63.  
  64. Author:   Maarten Meijer, Academic Computing Centre University of Utrecht,
  65.           the Netherlands. Email address: mmeijer@cc.ruu.nl
  66.  
  67. Version:  Mar 10, 1992.
  68.  
  69.  
  70. ------------------------------------------------------
  71. 3. Installation
  72.  
  73.  
  74. Running AAVIRUS with option -i without any other arguments will create a
  75. checksum file \AAVIRUS.DAT on the default drive (if you use DOS 3.x) or on
  76. the drive you booted from (if you use DOS 4 or higher). 
  77.  
  78. You may specify another filename and/or another bootable drive. In the latter
  79. case, you probably have to change the environment variable COMSPEC for a
  80. while, to point to the COMMAND.COM file used when you boot from that disk.
  81. AAVIRUS uses COMSPEC to locate the current command interpreter.
  82.  
  83. The checksum file contains the following
  84. -   the boot record and master boot record if it's a hard disk,
  85. -   the current COMSPEC environment variable, 
  86. -   the disk's volume label,
  87. -   the directory entries and checksums of the two hidden system files
  88.     (IO.SYS and MSDOS.SYS or IBMBIO.COM and IBMDOS.COM),
  89. -   the directory entry and checksum of COMMAND.COM (according to COMSPEC),
  90. -   the directory entry and checksum of the AAVIRUS program itself,
  91. -   the timestamp of creating the checksum file and its own checksum.
  92.  
  93. Before installation of the AAVIRUS checksum file always make sure that your
  94. disk isn't already infected by a virus, by using a recent virus scan program.
  95.  
  96.  
  97. ------------------------------------------------------
  98. 4. Checking bootstrap integrity
  99.  
  100.  
  101. The integrity of the bootstrap system is tested against the checksum file by
  102. the option -t. Putting the line "aavirus -t" in your AUTOEXEC.BAT will check
  103. the system when you start it. 
  104.  
  105. Normally AAVIRUS reports that "everything looks fine". You can suppress this
  106. one line message by redirecting output to null device ("aavirus -t >nul"),
  107. because if something appears to be changed, the AAVIRUS messages will reach
  108. your screen anyway (writing to standard error device), waking you up with
  109. beeps and requesting your acknowledgement.
  110.  
  111. Because checksumming the contents of 4 files (see above) takes some time,
  112. especially on slower systems, the option -q (quick test) checks everything
  113. (master boot record, boot record, COMSPEC, directory entries of hidden files,
  114. command interpreter and the program itself, and the integrity of the checksum
  115. file) - except the checksums on the 4 files contents. Use option -q in your
  116. AUTOEXEC.BAT if option -t takes too long. 
  117.  
  118. If AAVIRUS reports any differences between the checksum file and the actual
  119. situation, there is the possibility of virus infection, but the symptoms may
  120. also be caused by quite normal actions like changing the boot disk's volume
  121. label (which affects the boot record of DOS 4 and above), upgrading DOS,
  122. changing COMSPEC (the location of COMMAND.COM), changing file attributes
  123. (e.g. the archive attribute after backup), getting a new version of AAVIRUS,
  124. and so on. 
  125.  
  126. To get acquainted with AAVIRUS' operation, you could try it: change something
  127. for a while, then run "aavirus -t" or "aavirus -q". The real disk heroes are
  128. challenged to alter their boot record or partition table and try "aavirus -r"
  129. or "aavirus -e" too (see below).
  130.  
  131. So don't get upset if AAVIRUS cries, but use your memory (Did I recently
  132. change something?) and a recent copy of a virus scan program.
  133.  
  134. By the way, AAVIRUS will only discover viruses that affect the bootstrap
  135. system, as by definition all partition table and boot record viruses do. 
  136. It is not suited to signal infection of .COM and .EXE files, although it
  137. checks COMMAND.COM and its own integrity - being of the .EXE species.
  138. So, use a virus scan program anyway, from time to time. Personally, I don't
  139. like memory resident virus watchers. It's too much paranoia to have it
  140. interfere with the normal functioning of the system, as they too often do.
  141.  
  142.  
  143. ------------------------------------------------------
  144. 5. Repair options
  145.  
  146.  
  147. AAVIRUS is able to restore the boot record and the master boot record from
  148. the checksum file to their original locations in two ways. 
  149.  
  150. The first method (option -r) reads the given checksum file and restores
  151. either or both sectors after prompting. A lot of boot sector viruses (those
  152. that do not intercept writing to sector 0 at BIOS level) can be removed by
  153. simply restoring the original bootrecord this way and rebooting the system.
  154.  
  155. The second method (option -e) has to be used when the checksum file resided
  156. on hard disk #0 (in any partition) but has been lost (yet not overwritten!)
  157. or when the hard disk isn't accessible to DOS anymore. 
  158. The program scans the entire disk at the BIOS level to find the most recent
  159. file data, using the data's checksum and timestamp (see chapter 3). Formally
  160. you should complete the scanning process to be sure you have got the most
  161. recent data, but if you installed the checksum file just once, you may
  162. interrupt scanning as soon as data are found. You will then be prompted to
  163. restore either or both records.
  164.  
  165.  
  166. ------------------------------------------------------
  167. 6. Some technical details
  168.  
  169.  
  170. AAVIRUS requires or assumes the following technical specifications:
  171. -   PC-DOS or MS-DOS version 3.0 or above
  172. -   hidden system files should be either IO.SYS and MSDOS.SYS or IBMBIO.COM
  173.     and IBMDOS.COM
  174. -   standard sector size of 512 bytes
  175. -   a one sector boot record
  176. -   if a hard disk: a one sector master boot record at cylinder 0 head 0
  177.     sector 1
  178.  
  179. If you're not sure your system meets all these standards: they're quite
  180. common. But read the exceptions below.
  181.  
  182. The source code of AAVIRUS has been written in Turbo C 2.0 from Borland with
  183. a few functions in Microsoft MASM 4.0 assembler. 
  184.  
  185. The current version of AAVIRUS has been tested on several systems of
  186. different model and brand, with hard disks varying from 20 up to 110 MB, with
  187. one or more partitions per disk and different BIOS parameters, using DOS
  188. versions 3.30 and 5.0. I wiped partition tables and boot sectors, and was
  189. able to restore them from the checksum file using either the -e or -r option.
  190.  
  191. I did NOT test the program with memory resident disk handlers (other than
  192. DOS's) that compress, encrypt, or relocate data. Restoring boot records
  193. without having these same handlers loaded, will obviously produce wrong
  194. results. 
  195. Also, it seems that Digital Research DOS (DR-DOS) uses two sectors for its
  196. boot record or partition table. If that is true, AAVIRUS isn't suitable to
  197. DR-DOS users. Perhaps the same goes for other DOS-like operating systems as
  198. well. Let me know if you have more definitive information on these issues.
  199.  
  200.  
  201. ------------------------------------------------------
  202. 7. Concluding remarks
  203.  
  204.  
  205. So, if you use common hardware and common DOS, I don't expect you will run
  206. into any trouble using this program. BUT:
  207.  
  208. >>  Nor I, nor my employer, will accept liability for any damage caused by
  209. >>  or following the use of this program! You will use it at your own risk!
  210.  
  211. If you have any questions or remarks concerning the program, please don't
  212. hesitate to write me at my mail address: mmeijer@cc.ruu.nl.
  213.  
  214. You may freely use, copy and distribute this program, on the simple terms
  215. that program and documentation will not be modified in any way, will not be
  216. sold, and are distributed together.
  217.  
  218.  
  219. ======================================================
  220.